package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.ExamAnswerMapper;
import com.ruoyi.system.domain.ExamAnswer;
import com.ruoyi.system.service.IExamAnswerService;

/**
 * 标准答案Service业务层处理
 * 
 * @author tyro
 * @date 2025-05-21
 */
@Service
public class ExamAnswerServiceImpl implements IExamAnswerService 
{
    @Autowired
    private ExamAnswerMapper examAnswerMapper;

    /**
     * 查询标准答案
     * 
     * @param id 标准答案主键
     * @return 标准答案
     */
    @Override
    public ExamAnswer selectExamAnswerById(Long id)
    {
        return examAnswerMapper.selectExamAnswerById(id);
    }

    /**
     * 查询标准答案列表
     * 
     * @param examAnswer 标准答案
     * @return 标准答案
     */
    @Override
    public List<ExamAnswer> selectExamAnswerList(ExamAnswer examAnswer)
    {
        return examAnswerMapper.selectExamAnswerList(examAnswer);
    }

    /**
     * 新增标准答案
     * 
     * @param examAnswer 标准答案
     * @return 结果
     */
    @Override
    public int insertExamAnswer(ExamAnswer examAnswer)
    {
        return examAnswerMapper.insertExamAnswer(examAnswer);
    }

    /**
     * 修改标准答案
     * 
     * @param examAnswer 标准答案
     * @return 结果
     */
    @Override
    public int updateExamAnswer(ExamAnswer examAnswer)
    {
        return examAnswerMapper.updateExamAnswer(examAnswer);
    }

    /**
     * 批量删除标准答案
     * 
     * @param ids 需要删除的标准答案主键
     * @return 结果
     */
    @Override
    public int deleteExamAnswerByIds(Long[] ids)
    {
        return examAnswerMapper.deleteExamAnswerByIds(ids);
    }

    /**
     * 删除标准答案信息
     * 
     * @param id 标准答案主键
     * @return 结果
     */
    @Override
    public int deleteExamAnswerById(Long id)
    {
        return examAnswerMapper.deleteExamAnswerById(id);
    }
}
